gtkwindow: Do not account handle size when checking content area
authorCarlos Garnacho <carlosg@gnome.org>
Sat, 9 Dec 2017 16:32:02 +0000 (17:32 +0100)
committerCarlos Garnacho <carlosg@gnome.org>
Sat, 9 Dec 2017 16:32:02 +0000 (17:32 +0100)
This is necessary to bring back the L-shaped resize corners. On all edges
(not corners) the handle width is determined by the border size.

gtk/gtkwindow.c

index 9396dfc93861de94a4a89fe51a418267226d23c3..aba18df0121330d41f574e68d7a31a40d4f4bf2a 100644 (file)
@@ -1744,10 +1744,10 @@ edge_under_coordinates (GtkWindow     *window,
   gtk_style_context_restore (context);
 
   /* Check whether the click falls outside the handle area */
-  if (x >= allocation.x + border.left + handle_h &&
-      x < allocation.x + allocation.width - border.right - handle_h &&
-      y >= allocation.y + border.top + handle_v &&
-      y < allocation.y + allocation.height - border.bottom - handle_v)
+  if (x >= allocation.x + border.left &&
+      x < allocation.x + allocation.width - border.right &&
+      y >= allocation.y + border.top &&
+      y < allocation.y + allocation.height - border.bottom)
     return FALSE;
 
   /* Check X axis */